public class Test03 {
    public static void main(String[] args) {
        int max = 999;
        int a = 1;
        for (int num = 100;num <= max;num++)
        {
            int b = num % 10;
            //System.out.println("b:" + b);
            int t = (num/10) % 10;
            //System.out.println("t:" + t);
            int h = num/100;
            //System.out.println("h:" + h);
            int product = b*b*b + t*t*t + h*h*h;
            //System.out.println("product:" + product);
            if (num == product)
            {
                if (a % 2 == 1){
                    //a = a + 1;
                    System.out.print(num + " 和 ");
                }else {
                    System.out.println(num + "是水仙花数");
                }
                a++;
            }
        }
        //System.out.println(a);
    }
}
